package com.blb.mapper;

import com.blb.entity.Certificate;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ZhengSanNan
 * @since 2019-12-24
 */
public interface CertificateMapper extends BaseMapper<Certificate> {
    @Select("select * from t_certificate where certificate=#{certificate}")
    Certificate findUserByCertificate(String certificate);

    @Update("update t_certificate SET token = #{token} WHERE certificate = #{certificate}")
    void updateToken(String certificate,String token);
}
